Get premium membership and access questions with answers, video lessons as well as revision papers.

Given the following base class, show how it can be inherited by a derived class called mars class planet { int moons; double dist_from_sun; double diameter; double mass public: // ... };

      

Given the following base class, show how it can be inherited by a derived class called mars
class planet {
int moons;
double dist_from_sun;
double diameter;
double mass
public:
// ...
};

  

Answers


Davis
class Mars : public planet {
//...
};
Githiari answered the question on May 12, 2018 at 16:44


Next: Given the following class, what are the names of its constructor and destructor functions? class widgit { int x, y; public : //.....fill in constructor and destructor functions };
Previous: Outline five methods of personal selling in product promotion.

View More Computer Science Questions and Answers | Return to Questions Index


Learn High School English on YouTube

Related Questions